package com.lanou3g.demo.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

public class AdminInfo {
    private Integer adminId;

    @NotBlank(message = "不能为空")
    @NotNull(message = "不能为空")
    private String adminCode;

    @NotBlank(message = "不能为空")
    @NotNull(message = "不能为空")
    private String password;

    @NotBlank(message = "不能为空")
    @NotNull(message = "不能为空")
    private String name;

    @NotBlank(message = "不能为空")
    @NotNull(message = "不能为空")
    private String telephone;

    @NotBlank(message = "不能为空")
    @NotNull(message = "不能为空")
    private String email;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date enrolldate;

//    private AdminRole adminRole;


    private List<AdminRole> roleList;


    public AdminInfo() {
    }


    public List<AdminRole> getRoleList() {
        return roleList;

    }

//    public AdminRole getAdminRole() {
//        return adminRole;
//    }
//
//    public void setAdminRole(AdminRole adminRole) {
//        this.adminRole = adminRole;
//    }

    public Integer getAdminId() {
        return adminId;
    }

    public void setAdminId(Integer adminId) {
        this.adminId = adminId;
    }

    public String getAdminCode() {
        return adminCode;
    }

    public void setAdminCode(String adminCode) {
        this.adminCode = adminCode;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getTelephone() {
        return telephone;
    }

    public void setTelephone(String telephone) {
        this.telephone = telephone;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    public Date getEnrolldate() {
        return enrolldate;
    }

    public void setEnrolldate(Date enrolldate) {
        this.enrolldate = enrolldate;
    }
}